nginx 负载均衡
upstream jenkins {
server 192.168.0.39:9090;
}
server{
listen 80;
server_name jenkins-prod.buddyniu.com;
charset utf-8;
access_log /var/log/nginx/access.log main;
location / {
proxy_redirect off;
proxy_set_header Host $host;
proxy_set_header X-Real-Ip $remote_addr;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_pass http://jenkins;
client_max_body_size 20m;
proxy_read_timeout 120s;
proxy_connect_timeout 120s;
}
}